-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Fix: Added null checks for ShellViewModel in navigation helpers #17963
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
+27
−14
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
hishitetsu
reviewed
Dec 23, 2025
hishitetsu
reviewed
Dec 23, 2025
hishitetsu
reviewed
Dec 23, 2025
Member
hishitetsu
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's better to reuse the instance that has been verified as non-null rather than checking for non-null every time.
Co-authored-by: hishitetsu <[email protected]> Signed-off-by: Yair <[email protected]>
Co-authored-by: hishitetsu <[email protected]> Signed-off-by: Yair <[email protected]>
hishitetsu
approved these changes
Dec 24, 2025
Member
|
@hishitetsu thank you for the review. |
yaira2
added a commit
to Anoop-2024si96509/Files
that referenced
this pull request
Jan 6, 2026
commit 13385cb Author: Anoop-2024si96509 <[email protected]> Date: Tue Jan 6 00:36:45 2026 +0530 Fix: Fixed an issue where file types displayed differently for hidden items (files-community#18018) commit 124e1fc Author: Saravanan G <[email protected]> Date: Mon Jan 5 21:29:05 2026 +0530 Fix: Fixed an issue where search didn't work for tags with spaces in their name (files-community#18020) commit c1484c2 Author: Steve <[email protected]> Date: Mon Jan 5 00:54:06 2026 +0900 Code Quality: Cleanup warnings (files-community#18011) Signed-off-by: Steve <[email protected]> Co-authored-by: Copilot <[email protected]> Co-authored-by: Copilot <[email protected]> commit 528be10 Author: Saravanan G <[email protected]> Date: Thu Jan 1 01:49:38 2026 +0530 Fix: Prevent "Failed to enqueue the operation" exception during shutdown (files-community#18006) commit babc715 Author: 0x5BFA <[email protected]> Date: Mon Dec 29 07:27:11 2025 +0900 Code Quality: Suppress exceptions that can occur in SidebarView drag/drop event handlers (files-community#17996) commit 01ddde9 Author: Yair <[email protected]> Date: Thu Dec 25 16:38:12 2025 -0500 Build: v4.0.24 commit 3ad75f1 Author: Yair <[email protected]> Date: Thu Dec 25 16:37:34 2025 -0500 Code Quality: Updated translations (files-community#17997) commit e21ef88 Author: seer-by-sentry[bot] <157164994+seer-by-sentry[bot]@users.noreply.github.com> Date: Tue Dec 23 19:46:54 2025 -0500 Fix: Added null checks for ShellViewModel in navigation helpers (files-community#17963) Signed-off-by: Yair <[email protected]> Co-authored-by: seer-by-sentry[bot] <157164994+seer-by-sentry[bot]@users.noreply.github.com> Co-authored-by: Yair <[email protected]> Co-authored-by: hishitetsu <[email protected]> commit 25bdcd1 Author: Yair <[email protected]> Date: Mon Dec 22 18:32:10 2025 -0500 Build: v4.0.23 commit 6721e58 Author: Yair <[email protected]> Date: Mon Dec 22 18:27:25 2025 -0500 Code Quality: Updated translations (files-community#17986) commit 0c21660 Author: Yair <[email protected]> Date: Mon Dec 22 17:47:00 2025 -0500 Feature: Added text wrapping to Status Center (files-community#17985) commit 9afe596 Author: 0x5BFA <[email protected]> Date: Tue Dec 23 01:43:23 2025 +0900 Code Quality: Removed ISidebarViewModel (files-community#17972) commit 347c35d Author: 0x5BFA <[email protected]> Date: Sun Dec 21 08:40:37 2025 +0900 GitHub: Removed the extra link space between the download badges (files-community#17975) commit bb05ce1 Author: Saravanan G <[email protected]> Date: Fri Dec 19 20:53:32 2025 +0530 Feature: Added Copy functionality to sidebar and home page widgets (files-community#17969) commit 472347c Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu Dec 18 10:45:37 2025 -0500 Bump Microsoft.WindowsAppSDK from 1.8.250907003 to 1.8.251106002 (files-community#17974) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> commit 81aa50c Author: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu Dec 18 10:45:27 2025 -0500 Bump Microsoft.Windows.SDK.BuildTools from 10.0.26100.4948 to 10.0.26100.7175 (files-community#17973) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> commit e49e479 Author: 0x5BFA <[email protected]> Date: Thu Dec 18 02:55:24 2025 +0900 Feature: Added theme shadow to Omnibar flyout (files-community#17971) commit 1d66171 Author: Marlen Halvorsen <[email protected]> Date: Wed Dec 17 00:53:29 2025 +0100 Feature: Added default name when creating new files (files-community#17942) Co-authored-by: Yair <[email protected]> commit 014d34d Author: Saravanan G <[email protected]> Date: Tue Dec 16 21:01:41 2025 +0530 Code Quality: Additional logs to troubleshoot crashes (files-community#17955) commit f56c965 Author: Yair <[email protected]> Date: Mon Dec 15 12:18:46 2025 -0500 Code Quality: Change provider detection order in PreviewPopupService Moved PowerToysPeekProvider availability check after QuickLookProvider and SeerProProvider in GetProviderAsync. This alters the priority in which preview providers are selected. commit 929c304 Author: Yair <[email protected]> Date: Sun Dec 14 10:19:27 2025 -0500 Build: v4.0.22 Signed-off-by: Yair <[email protected]> commit 7def439 Author: Yair <[email protected]> Date: Wed Dec 10 18:19:38 2025 -0500 Feature: Added support for PowerToys Peek (files-community#17954) commit 6cca0bb Author: Saravanan G <[email protected]> Date: Wed Dec 10 21:17:46 2025 +0530 Fix: Fixed crash that would sometimes occur when resizing the window (files-community#17893) commit e7eaf16 Author: Barton Milnor Mallory <[email protected]> Date: Tue Dec 9 18:24:54 2025 -0600 Code Quality: Fixed typos in code comments (files-community#17945) commit ddeb2ff Author: Saravanan G <[email protected]> Date: Thu Dec 4 00:53:07 2025 +0530 Fix: Fixed crash when switching git branches during merge conflict (files-community#17894) Signed-off-by: Saravanan G <[email protected]> Co-authored-by: Yair <[email protected]> commit 4abd5f2 Author: Kalmix <[email protected]> Date: Wed Dec 3 11:34:58 2025 -0400 Fix: Fixed PNG-based .ico files rendering with black backgrounds (files-community#17924)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix: Add null checks to OpenPath methods to prevent NRE
Resolved / Related Issues
To prevent extra work, all changes to the Files codebase must link to an approved issue marked as
Ready to build. Please insert the issue number following the hashtag with the issue number that this Pull Request resolves.Fixes FILES-APP-2MN. The issue was that: Asynchronous execution of
OpenPathallowsassociatedInstance.ShellViewModelto become null before subsequent access, causing NullReferenceException.associatedInstance.ShellViewModelinOpenSelectedItemsAsyncandOpenItemsWithExecutableAsync.associatedInstance.ShellViewModelthroughout theOpenPathmethod to prevent potential crashes during navigation.This fix was generated by Seer in Sentry, triggered by Yair. 👁️ Run ID: 7531953
Not quite right? Click here to continue debugging with Seer.
Steps used to test these changes
Stability is a top priority for Files and all changes are required to go through testing before being merged into the repo. Please include a list of steps that you used to test this PR.
OpenSelectedItemsAsync) and items with executables (OpenItemsWithExecutableAsync) functions correctly without crashing.OpenPathremains stable and does not throw NullReferenceException.